import { createBrowserRouter, RouterProvider } from 'react-router-dom';
import MainLayout from '../layouts/MainLayout';
import HomePage from '../pages/home';
import EmploymentPage from '../pages/employment';
import TeamPage from '../pages/team';
import ArticlesPage from '../pages/articles';
import JoinPage from '../pages/join';
import ContactPage from '../pages/contact';
import DemoPage from '../pages/demo';

const router = createBrowserRouter([
  {
    path: '/',
    element: <MainLayout />,
    children: [
      {
        index: true,
        element: <HomePage />,
      },
      {
        path: 'employment',
        element: <EmploymentPage />,
      },
      {
        path: 'team',
        element: <TeamPage />,
      },
      {
        path: 'articles',
        element: <ArticlesPage />,
      },
      {
        path: 'join',
        element: <JoinPage />,
      },
      {
        path: 'contact',
        element: <ContactPage />,
      },
      {
        path: 'demo',
        element: <DemoPage />,
      },
    ],
  },
]);

const Router = () => {
  return <RouterProvider router={router} />;
};

export default Router;